package com.wnhz.work.yz.activity;

import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.widget.TextView;

import com.wnhz.work.yz.BaseActivity;
import com.wnhz.work.yz.R;

public class AddRecordActivity extends BaseActivity implements View.OnClickListener {

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_add_record);
        initTitle();
    }

    private void initTitle() {
        TextView title = (TextView) findViewById(R.id.view_main_middle_title);
        title.setText("新增客户信息");
        //title.setTextSize(18);
        findViewById(R.id.btn_main_left).setOnClickListener(this);
        findViewById(R.id.clues_search).setOnClickListener(this);
        findViewById(R.id.accurate_search).setOnClickListener(this);
    }

    @Override
    public void onClick(View v) {
        switch (v.getId()) {
            case R.id.btn_main_left:
                finish();
                break;
            //线索添加
            case R.id.clues_search:
                Intent intent = new Intent(this, AddAccurateActivity.class);
                intent.putExtra("type", 0);
                startActivity(intent);
                break;
            //精确添加
            case R.id.accurate_search:
                Intent intent2 = new Intent(this, AddAccurateActivity.class);
                intent2.putExtra("type", 1);
                startActivity(intent2);
                break;

        }
    }
}
